//  Paint to make a rectangle

#include <bits/stdc++.h>

using namespace std;
constexpr int inf = 1e9;

int main() {
  int n, m;
  cin >> n >> m;
  int minx = inf, miny = inf, maxx = -inf, maxy = -inf;
  vector<string> s(n);
  for (int i = 0; i < n; i++) {
    cin >> s[i];
  }
  for (int i = 0; i < n; i++) {
    for (int j = 0; j < m; j++) {
      if (s[i][j] == '#') {
        minx = min(minx, j);
        miny = min(miny, i);
        maxx = max(maxx, j);
        maxy = max(maxy, i);
      }
    }
  }

  for (int i = miny; i <= maxy; i++) {
    for (int j = minx; j <= maxx; j++) {
      if (s[i][j] == '.') {
        cout << "No";
        return 0;
      }
    }
  }
  cout << "Yes";
  return 0;
}
